<!-- 
    Security Knowledge Framework is an expert system application 
    that uses OWASP Application Security Verification Standard, code examples,
    helps developers in pre-development and post-development.  
    Copyright (C) 2020  Glenn ten Cate, Riccardo ten Cate

    This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU Affero General Public License as
    published by the Free Software Foundation, either version 3 of the
    License, or (at your option) any later version.

    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU Affero General Public License for more details.

    You should have received a copy of the GNU Affero General Public License
    along with this program. If not, see <http://www.gnu.org/licenses/>.
-->

<div style="z-index:100;" id="login" class="container">

  <div class="col-wrapper">
    <div class="lock-screen">
      <div class="login-wrapper">
        <div class="logo"><img src="assets/img/logos/logo_login.svg" width="60" height="60" /></div>
        <div *ngIf="expired">
          <br/>
          <ngb-alert [dismissible]="false">
            <strong>Warning!</strong> Your session has expired!
          </ngb-alert>
        </div>
        <div class="modal-dialog">
          <div class="modal-content">
            <div class="modal-header">
              <h4 style="text-align: center" class="modal-title">Security Knowledge Framework</h4>
            </div>
            <div class="modal-body">
              <form [formGroup]="loginForm">
                <input formControlName="username" name="username" id="username" placeholder="Username" autocomplete="off" class="form-control placeholder-no-fix"
                />
                <br>
                <input formControlName="password" name="password" id="password" type="password" placeholder="Password" autocomplete="off" class="form-control placeholder-no-fix"
                />
                <span *ngFor="let errors of error" style="color:red;">
                <br/> 
                {{errors}}
                </span>
                <div class="modal-footer centered">
                  <a style="text-align:center; color:#515594" href="#" routerLink="/first-login">first-login</a>
                  <button (click)="onLogin()" class="btn btn-theme03" type="submit">Login</button>
                  <button (click)="skipLogin()"  class="btn btn-theme04" type="submit">Skip</button>
                </div>
              </form>
            </div>
            <!-- js placed at the end of the document so the pages load faster -->
            <script src="assets/js/bootstrap.min.js"></script>
          </div>
        </div>
      </div>
      <div  class="copy">
        <img src="assets/img/logos/owasp-icon-grey.svg" width="40" height="40" />Supported by <a style="color:#4d6aa9;" href="https://www.owasp.org/index.php?title=OWASP_Security_Knowledge_Framework">OWASP</a>
      </div>
    </div>
  </div>
</div>
